<?php
	//includes
	require_once 'includes.php';

	//delete all
	DB::ExecuteSQL("
		DELETE FROM t_restaurant_state_urls;
	");
	
	$startTime = microtime() + time();
	
	//OpenTable (restaurant source)
	$openTable = new OpenTable(); 

	//gets all URLs
	$openTable->GetStateUrls();
	
	//saves restaurant URLs
	$result = $openTable->SaveStateUrls();
	
	$endTime = microtime() + time();
	
	//totals
	$resultTime = $endTime - $startTime;
	echo "Total time: $resultTime; Success: {$result['success']}; Fail: {$result['fail']}; ";
?>